﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using AutoRegisterManager.Common;
using SystemFramework.IDCard;
namespace AutoRegisterManager
{
    //等待读取身份证信息
    public partial class FrmWaitCard2 : Form
    {
        int sec = 1;
        public FrmWaitCard2()
        {
            InitializeComponent();
            timer1.Start();
         
        }

        private void lblcancle_Click(object sender, EventArgs e)
        {
            this.DialogResult = DialogResult.Cancel;
        }

        private void timer1_Tick(object sender, EventArgs e)
        {
            try
            {
                if (sec == 0)
                {
                    this.timer1.Stop();
                    this.DialogResult = DialogResult.OK;
                }
                this.lblWaitTime.Text = sec.ToString();
                sec = sec - 1;
            }
            catch (Exception ex)
            {
                timer1.Stop();
                MyMsg.MsgInfo(ex.Message);
               
            }
                
               
        }

        private void FrmWaitCard_FormClosing(object sender, FormClosingEventArgs e)
        {
         
        }

     

     

    }
}
